﻿using Coder.Workflow;
using Fee.Orders;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Metadata.Builders;

namespace Fee.Mapping.Orders
{
    public class DelegateOrderBaseMapping : IEntityTypeConfiguration<DelegateOrderBase>
    {
        public void Configure(EntityTypeBuilder<DelegateOrderBase> builder)
        {
            builder.HasBaseType<ProcessInstance>();
            builder.HasMany(_ => _.Details).WithOne().HasConstraintName("FK_BaseOrder_Detail");
        }
    }
}